package com.bytecollege.mapper;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.bytecollege.model.Footmark;
import com.bytecollege.vo.FootMarkVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.io.Serializable;
import java.util.Collection;
import java.util.List;

/**
 * @ClassName: FootmarkMapper
 * @Description:
 * @Author: Sun
 * @Date: 2022/10/18 21:03
 */
@Mapper
public interface FootmarkMapper extends BaseMapper<Footmark> {
    /**
     * 我的足迹
     * @param page 页数
     * @param
     * @return
     */
    @Select("select u.User_NickName,u.User_Id,footmark_id, footmark_name, addtime from footmark join user u on footmark.User_Id = u.User_Id  where u.User_Id = #{userId}")
    List<FootMarkVo> getAllFootMark(Page page, @Param("userId") Integer userId);
}